﻿<%@ Page Title="" Language="C#" MasterPageFile="~/MasterPage.master" AutoEventWireup="true" CodeFile="Register.aspx.cs" Inherits="register" %>


<asp:Content ID="Content1" ContentPlaceHolderID="body" Runat="Server">
    <div style="background-position: right bottom; margin: 20px; height:425px; background-image: url('Images/student.jpg'); background-repeat: no-repeat;" >
        <table style="width:100%">
            <tr>
                <td colspan="3">
                    <span ><span style="font-size: x-large">欢迎注册同学录</span><br />
                    <br />
                    </span></td>
            </tr>
            <tr>
                <td style="width: 59px">
                    用户名:</td>
                <td style="width: 90px">
                    <asp:TextBox ID="TextBox1" runat="server"></asp:TextBox>
                </td>
                <td style="width: 438px">
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator1" runat="server" 
                        ControlToValidate="TextBox1" ErrorMessage="用户名不能为空"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td style="width: 59px">
                    密码:</td>
                <td style="width: 90px">
                    <asp:TextBox ID="TextBox2" runat="server" TextMode="Password" Width="147px"></asp:TextBox>
                </td>
                <td style="width: 438px">
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator2" runat="server" 
                        ControlToValidate="TextBox2" ErrorMessage="密码不能为空"></asp:RequiredFieldValidator>
                </td>
            </tr>
            <tr>
                <td style="width: 59px">
                    邮箱:</td>
                <td style="width: 90px">
                    <asp:TextBox ID="TextBox3" runat="server"></asp:TextBox>
                </td>
                <td style="width: 438px">
                    <asp:RequiredFieldValidator ID="RequiredFieldValidator3" runat="server" 
                        ControlToValidate="TextBox3" ErrorMessage="邮箱不能为空" Display="Dynamic"></asp:RequiredFieldValidator>
                    <asp:RegularExpressionValidator ID="RegularExpressionValidator1" runat="server" 
                        ControlToValidate="TextBox3" Display="Dynamic" ErrorMessage="邮箱格式不正确" 
                        ValidationExpression="^[_\.0-9a-z-]+@([0-9a-z][0-9a-z-]+\.){1,4}[a-z]{2,3}$"></asp:RegularExpressionValidator>
                </td>
            </tr>
     
            <tr>
                <td colspan="3" style="height: 41px">
                    <asp:Label ID="Label1" runat="server" ForeColor="Red"></asp:Label>
                    <br />
                    <br />
                    <asp:Button ID="Button1" runat="server" onclick="Button1_Click" Text="注册" />
                    <input id="Button2" type="button" value="取消" onclick="javascript:history.go(-1);"  />
                    <br />
                </td>
            </tr>
        </table>

</div>
</asp:Content>

